1. Field of the Invention
The present invention relates generally to computer aided design documents, and more particularly to display ordering of elements in a two-dimensional computer aided design document.
2. Related Art
Computer-aided design (CAD) drawings prepared by architects, engineers, designers, planners, and the like require large amounts of data to be stored in files. CAD software includes an API to access the large quantities of data. Applications such as, e.g., MicroStation® products, which are developed by Bentley Systems, Inc., Exton, Pa. U.S.A. are typical of such CAD software, which may be used in the Architecture, Engineering, Construction, and Operations (AECO) marketplace.
A typical CAD project employed in the engineering context is stored in numerous files. Each file typically contains one or more engineering models, each of which typically represents an engineering domain (e.g., structural, electrical, mechanical, plumbing). Moreover, each engineering model contains numerous elements that collectively represent the complex and precise nature of each design. Each item in a model is represented by at least one element or an aggregation of elements. For example, a structural drawing can hold the column and beam layout for a floor plan, which are internally represented by lines, squares and rectangles and additional properties. In this example, an individual beam element may be a collection of lines, squares and rectangles. The structure of the floor plan may be more complex and require many levels of elements to accurately provide a structural representation.
In known CAD software, the last element added to a two dimensional design image is usually displayed on top of other existing elements. That is, the last element added obscures any previously drawn element if both elements occupy the same two-dimensional space in the image. This is commonly referred to as the painter's algorithm. As in painting, the last paint applied to a surface obscures previously applied paint. The painter's algorithm defines the overlay of the elements in the image according to the sequence in which the elements are drawn.
Many CAD and other graphics programs allow the user to reorder elements. The user may select an element and perform a “send-to-back” or “bring-to-front” process on the element. These processes reorder the sequence in which the elements are drawn. The reordering therefore changes the visibility of the element relative to the other elements in that particular image. This resequencing can either be accomplished by physically reordering the elements in memory or by keeping a separate “sort order” list.
The above approach works fine for specifying the relative order of specific elements (e.g. this one is in front of that one), but provides no systematic way for users to specify relative priorities for types or groups of elements. Also, with the painter's algorithm, maintaining proper sequencing of elements in the face of changes is difficult. For example, when making a copy of an element, there is no predictable way for the user to specify the relative priority of the new element with respect to the old element, or other elements in the same vicinity. Typically, if the user wishes to copy an element and use it elsewhere in the image or in another image, the copied element is placed at the end of the list, and therefore on top of all other elements. A reordering operation must be performed to move the element to the desired position. Similarly, if a user has a preference about a certain type of element, such as a text label, the user typically has to remember to place that element at the appropriate moment in the image construction. Otherwise the user must re-order each instance of the element type.
Furthermore, some CAD programs provide a Level (sometimes referred to as a “Layer”) system whereby the image can be built from elements on a collection of Levels. For example, in an architectural drawing, the structural, electrical and plumbing disciplines might each have their own set of Levels in the image. Users can then view a limited subset of the Levels in order to reduce complexity. Since Level is typically implemented as an attribute of an Element, Level does not participate in display ordering. However, the user may wish to sort the display of Elements based on Level such that all elements on one Level appear in front of all Elements on another Level.
Accordingly, there is a need for an improved method and system for setting display priority that overcomes shortcomings of conventional solutions.